package com.cstp.service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.cstp.entity.Question;
import com.cstp.mapper.QuestionMapper;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author watts
 */
@Service
public class QuestionService extends ServiceImpl<QuestionMapper, Question> {

    @Cacheable(value = "purchase", key = "'purchase-all'")
    public List<Question> all() {
        return this.list();
    }
}
